package com.dianjing.dianqun.dao;

import org.apache.ibatis.annotations.Param;

import com.dianjing.dianqun.common.base.CrudMpper;
import com.dianjing.dianqun.model.ContentLike;

public interface ContentLikeMapper extends CrudMpper<ContentLike> {
	/**
	 *
	 * @mbggenerated 2017-11-03
	 */
	int deleteByPrimaryKey(Integer conetntLikeId);

	/**
	 *
	 * @mbggenerated 2017-11-03
	 */
	int insert(ContentLike record);

	/**
	 *
	 * @mbggenerated 2017-11-03
	 */
	int insertSelective(ContentLike record);

	/**
	 *
	 * @mbggenerated 2017-11-03
	 */
	ContentLike selectByPrimaryKey(Integer conetntLikeId);

	/**
	 *
	 * @mbggenerated 2017-11-03
	 */
	int updateByPrimaryKeySelective(ContentLike record);

	/**
	 *
	 * @mbggenerated 2017-11-03
	 */
	int updateByPrimaryKey(ContentLike record);

	ContentLike selectLikeByUser(@Param("userId")Integer userId,@Param("contentId") Integer contentId);

	Integer selectLikeByContentId(@Param("contentId")Integer contentId);

	void cancelLikeByContentId(@Param("userId")Integer userId,@Param("contentId") Integer contentId);
}